const {ccclass, property} = cc._decorator;

@ccclass
export default class Collision extends cc.Component {

    @property({displayName: "是否调试", tooltip: "是否调试"})
    is_debug: boolean = false;

    onLoad(){
        let manager = cc.director.getCollisionManager();// 获取碰撞引擎
        manager.enabled = true;// 开启碰撞引擎
        if (this.is_debug == true) {
            manager.enabledDebugDraw = true;// 是否绘制碰撞组件的形状，默认为不绘制
            manager.enabledDrawBoundingBox = true;// 是否绘制碰撞组件的包围盒，默认为不绘制
        }
    }


}